<?php

namespace Jb\Utils\Comparison\Strategy;

use Jb\Object,
    Jb\Utils\Comparison\Comparable;

class String extends Object implements Comparable {

    private $sString;

    public function __construct($textString) {
        $this->sString = (string) $textString;
    }

    public function compareTo(Object $comparableObject) {
        if($this->sString == (string) $comparableObject->toString()) {
            return true;
        } else {
            return false;
        }
    }

    public function toString() {
        return $this->sString;
    }

}

?>
